package com.njitzx.mapper;

import com.njitzx.entity.dto.GoodsDTO;
import com.njitzx.entity.dto.GoodsPageDTO;
import com.njitzx.entity.po.Goods;
import java.io.Serializable;
import java.util.List;

import com.njitzx.entity.vo.GoodsPageVO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

/**
 * <p>
 * 商品表 Mapper 接口
 * </p>
 *
 * @author 周鑫
 * @since 2024-08-20
 */
@Mapper
public interface GoodsMapper  {

    List<Goods> select(Goods goods);

    Goods selectById(Integer goodsId);

    void insert(GoodsDTO goodsDTO);

    void update(Goods goods);

    void deleteById(Serializable goodsId);

    void deleteByIds(String[] split);

    List<GoodsPageVO> selectByPage(GoodsPageDTO goodsPageDTO);

    Integer selectIsExistCategory(Integer catId);

    int getCount();

    void updateStatus(@Param("goodsId") Integer goodsId, @Param("goodsState") Integer goodsState);
}
